Optimal. Leaf size=182 \[ \frac {5 e n x^2}{36 a}-d n x \tan ^{-1}(a x)-\frac {1}{9} e n x^3 \tan ^{-1}(a x)-\frac {e x^2 \log \left (c x^n\right )}{6 a}+d x \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {d n \log \left (1+a^2 x^2\right )}{2 a}-\frac {e n \log \left (1+a^2 x^2\right )}{18 a^3}-\frac {\left (3 a^2 d-e\right ) \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )}{6 a^3}-\frac {\left (3 a^2 d-e\right ) n \text {Li}_2\left (-a^2 x^2\right )}{12 a^3} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.11, antiderivative size = 182, normalized size of antiderivative = 1.00, number of steps
used = 9, number of rules used = 10, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.556, Rules used = {5032, 1607,
455, 45, 2435, 4930, 266, 4946, 272, 2438} \begin {gather*} -\frac {n \left (3 a^2 d-e\right ) \text {PolyLog}\left (2,-a^2 x^2\right )}{12 a^3}+\frac {d n \log \left (a^2 x^2+1\right )}{2 a}-\frac {\left (3 a^2 d-e\right ) \log \left (a^2 x^2+1\right ) \log \left (c x^n\right )}{6 a^3}-\frac {e n \log \left (a^2 x^2+1\right )}{18 a^3}+d x \text {ArcTan}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \text {ArcTan}(a x) \log \left (c x^n\right )-d n x \text {ArcTan}(a x)-\frac {1}{9} e n x^3 \text {ArcTan}(a x)-\frac {e x^2 \log \left (c x^n\right )}{6 a}+\frac {5 e n x^2}{36 a} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 45
Rule 266
Rule 272
Rule 455
Rule 1607
Rule 2435
Rule 2438
Rule 4930
Rule 4946
Rule 5032
Rubi steps
\begin {align*} \int \left (d+e x^2\right ) \tan ^{-1}(a x) \log \left (c x^n\right ) \, dx &=-\frac {e x^2 \log \left (c x^n\right )}{6 a}+d x \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \tan ^{-1}(a x) \log \left (c x^n\right )-\frac {\left (3 a^2 d-e\right ) \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )}{6 a^3}-n \int \left (-\frac {e x}{6 a}+d \tan ^{-1}(a x)+\frac {1}{3} e x^2 \tan ^{-1}(a x)-\frac {\left (3 a^2 d-e\right ) \log \left (1+a^2 x^2\right )}{6 a^3 x}\right ) \, dx\\ &=\frac {e n x^2}{12 a}-\frac {e x^2 \log \left (c x^n\right )}{6 a}+d x \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \tan ^{-1}(a x) \log \left (c x^n\right )-\frac {\left (3 a^2 d-e\right ) \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )}{6 a^3}-(d n) \int \tan ^{-1}(a x) \, dx+\frac {\left (\left (3 a^2 d-e\right ) n\right ) \int \frac {\log \left (1+a^2 x^2\right )}{x} \, dx}{6 a^3}-\frac {1}{3} (e n) \int x^2 \tan ^{-1}(a x) \, dx\\ &=\frac {e n x^2}{12 a}-d n x \tan ^{-1}(a x)-\frac {1}{9} e n x^3 \tan ^{-1}(a x)-\frac {e x^2 \log \left (c x^n\right )}{6 a}+d x \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \tan ^{-1}(a x) \log \left (c x^n\right )-\frac {\left (3 a^2 d-e\right ) \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )}{6 a^3}-\frac {\left (3 a^2 d-e\right ) n \text {Li}_2\left (-a^2 x^2\right )}{12 a^3}+(a d n) \int \frac {x}{1+a^2 x^2} \, dx+\frac {1}{9} (a e n) \int \frac {x^3}{1+a^2 x^2} \, dx\\ &=\frac {e n x^2}{12 a}-d n x \tan ^{-1}(a x)-\frac {1}{9} e n x^3 \tan ^{-1}(a x)-\frac {e x^2 \log \left (c x^n\right )}{6 a}+d x \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {d n \log \left (1+a^2 x^2\right )}{2 a}-\frac {\left (3 a^2 d-e\right ) \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )}{6 a^3}-\frac {\left (3 a^2 d-e\right ) n \text {Li}_2\left (-a^2 x^2\right )}{12 a^3}+\frac {1}{18} (a e n) \text {Subst}\left (\int \frac {x}{1+a^2 x} \, dx,x,x^2\right )\\ &=\frac {e n x^2}{12 a}-d n x \tan ^{-1}(a x)-\frac {1}{9} e n x^3 \tan ^{-1}(a x)-\frac {e x^2 \log \left (c x^n\right )}{6 a}+d x \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {d n \log \left (1+a^2 x^2\right )}{2 a}-\frac {\left (3 a^2 d-e\right ) \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )}{6 a^3}-\frac {\left (3 a^2 d-e\right ) n \text {Li}_2\left (-a^2 x^2\right )}{12 a^3}+\frac {1}{18} (a e n) \text {Subst}\left (\int \left (\frac {1}{a^2}-\frac {1}{a^2 \left (1+a^2 x\right )}\right ) \, dx,x,x^2\right )\\ &=\frac {5 e n x^2}{36 a}-d n x \tan ^{-1}(a x)-\frac {1}{9} e n x^3 \tan ^{-1}(a x)-\frac {e x^2 \log \left (c x^n\right )}{6 a}+d x \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {1}{3} e x^3 \tan ^{-1}(a x) \log \left (c x^n\right )+\frac {d n \log \left (1+a^2 x^2\right )}{2 a}-\frac {e n \log \left (1+a^2 x^2\right )}{18 a^3}-\frac {\left (3 a^2 d-e\right ) \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )}{6 a^3}-\frac {\left (3 a^2 d-e\right ) n \text {Li}_2\left (-a^2 x^2\right )}{12 a^3}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.09, size = 165, normalized size = 0.91 \begin {gather*} \frac {5 a^2 e n x^2-6 a^2 e x^2 \log \left (c x^n\right )-4 a^3 x \tan ^{-1}(a x) \left (n \left (9 d+e x^2\right )-3 \left (3 d+e x^2\right ) \log \left (c x^n\right )\right )+18 a^2 d n \log \left (1+a^2 x^2\right )-2 e n \log \left (1+a^2 x^2\right )-18 a^2 d \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )+6 e \log \left (c x^n\right ) \log \left (1+a^2 x^2\right )+3 \left (-3 a^2 d+e\right ) n \text {Li}_2\left (-a^2 x^2\right )}{36 a^3} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
4.
time = 13.61, size = 78943, normalized size = 433.75
method | result | size |
risch | \(\text {Expression too large to display}\) | \(2700\) |
default | \(\text {Expression too large to display}\) | \(78943\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 54.39, size = 221, normalized size = 1.21 \begin {gather*} - d n \left (\begin {cases} 0 & \text {for}\: a = 0 \\\begin {cases} x \operatorname {atan}{\left (a x \right )} - \frac {\log {\left (a^{2} x^{2} + 1 \right )}}{2 a} & \text {for}\: a \neq 0 \\0 & \text {otherwise} \end {cases} + \frac {\operatorname {Li}_{2}\left (a^{2} x^{2} e^{i \pi }\right )}{4 a} & \text {otherwise} \end {cases}\right ) + d \left (\begin {cases} 0 & \text {for}\: a = 0 \\x \operatorname {atan}{\left (a x \right )} - \frac {\log {\left (a^{2} x^{2} + 1 \right )}}{2 a} & \text {otherwise} \end {cases}\right ) \log {\left (c x^{n} \right )} - \frac {e n x^{3} \operatorname {atan}{\left (a x \right )}}{9} + \frac {e x^{3} \log {\left (c x^{n} \right )} \operatorname {atan}{\left (a x \right )}}{3} + \frac {5 e n x^{2}}{36 a} - \frac {e n \left (\begin {cases} \frac {x^{2}}{2} & \text {for}\: a = 0 \\- \frac {\operatorname {Li}_{2}\left (a^{2} x^{2} e^{i \pi }\right )}{2 a^{2}} & \text {otherwise} \end {cases}\right )}{6 a} - \frac {e n \left (\begin {cases} x^{2} & \text {for}\: a^{2} = 0 \\\frac {\log {\left (a^{2} x^{2} + 1 \right )}}{a^{2}} & \text {otherwise} \end {cases}\right )}{18 a} - \frac {e x^{2} \log {\left (c x^{n} \right )}}{6 a} + \frac {e \left (\begin {cases} x^{2} & \text {for}\: a^{2} = 0 \\\frac {\log {\left (a^{2} x^{2} + 1 \right )}}{a^{2}} & \text {otherwise} \end {cases}\right ) \log {\left (c x^{n} \right )}}{6 a} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \ln \left (c\,x^n\right )\,\mathrm {atan}\left (a\,x\right )\,\left (e\,x^2+d\right ) \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________